import { View } from "@tarojs/components";
import ByText from "../ui/ByText";

export default ({
  source,
  address,
  className,
  round,
}: {
  source?: {
    customerName: string;
    decorationFullAddress?: string;
  };
  address?: string;
  className?: string;

  round?: boolean;
}) => {
  return (
    <>
      <View
        className={`bg-white shadow-black-1 p-3 ${
          round ? "rounded-xl" : "rounded-b-xl"
        } ${className}`}
      >
        <ByText bold className="text-lg">
          {source?.customerName}
        </ByText>
        <View className="mt-3 text-third text-sm">
          {address || source?.decorationFullAddress}
        </View>
      </View>
    </>
  );
};
